<?php
class Zend_Db_ActiveRecord_Oracle extends Zend_Db_ActiveRecord_Abstract
{
    /**
     * Transform a column name from the user-specified form
     * to the physical form used in the database.
     * You can override this method in a custom Row class
     * to implement column name mappings, for example inflection.
     *
     * @param string $columnName Column name given.
     * @return string The column name after transformation applied (none by default).
     * @throws Zend_Db_Table_Row_Exception if the $columnName is not a string.
     */
    protected function _transformColumn($columnName)
    {
        if (!is_string($columnName)) {
            require_once 'Zend/Db/Table/Row/Exception.php';
            throw new Zend_Db_Table_Row_Exception('Specified column is not a string');
        }
        // oracle column names are stored uppercased w/ underscores
        $columnName = strtoupper(preg_replace("/([a-z])([A-Z0-9])/", '$1_$2', $columnName));
        return $columnName;
    }
}
